package com.sos.core.cards
{
	
	import flash.events.Event;
	
	public class CardManagerEvent extends Event
	{
		
		// -------------------------------------------------------------------------------
		// CONSTANTS
		// -------------------------------------------------------------------------------
		
		// Events
		public static const         EVENT_LOAD_STARTED:String					= "cardManagerLoadStarted";
		public static const         EVENT_LOAD_COMPLETED:String					= "cardManagerLoadCompleted";
		public static const         EVENT_LOAD_CANCELLED:String					= "cardManagerLoadCancelled";
		public static const         EVENT_LOAD_FAILED:String					= "cardManagerLoadFailed";
		
		// -------------------------------------------------------------------------------
		// FIELDS
		// -------------------------------------------------------------------------------
		
		
		private var _cardManager:CardManager;
		private var _message:String;
		
		// -------------------------------------------------------------------------------
		// CONSTRUCTOR
		// -------------------------------------------------------------------------------
		
		/**
		 * Create a generic CardManager event
		 * @param t Event type name
		 * @param c CardManager reference
		 */		
		public function CardManagerEvent(type:String, cardManager:CardManager, message:String = "")
		{
			super(type);
			// Init
			_cardManager = cardManager;
			_message = message;
		}
		
		// -------------------------------------------------------------------------------
		// PROPERTIES
		// -------------------------------------------------------------------------------
		
		public function get cardManager():CardManager
		{
			return _cardManager;
		}

		public function get message():String
		{
			return _message;
		}

		
	}
}